package question4;

public class Product {
    private String title;
    private double weight;
    private String description;

    // 构造方法
    public Product(String title, double weight, String description) {
        this.title = title;
        this.weight = weight;
        this.description = description;
    }

    // Getter方法
    public String getTitle() {
        return title;
    }

    public double getWeight() {
        return weight;
    }

    public String getDescription() {
        return description;
    }

    // 计算指定数量商品的价格（需根据业务逻辑实现，此处为示例）
    public double getPriceForQuantity(int quantity) {
        // 假设单价为10.0
        return 10.0 * quantity;
    }
}
